package org.dromara.autocode.service;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.dromara.autocode.domain.entity.SysAutoCodeRule;
import org.dromara.common.mybatis.core.page.PageQuery;

import java.util.Collection;
import java.util.List;

/**
 * 编码生成规则Service业务层处理
 *
 * @author wenrui Su
 * @date 2025-03-19
 */

public interface SysAutoCodeRuleService  {

    /**
     * 查询编码生成规则
     */
    public SysAutoCodeRule queryById(Long ruleId);

    /**
     * 查询编码生成规则列表
     */
    public Page<SysAutoCodeRule> queryPageList(SysAutoCodeRule bo, PageQuery pageQuery);


    /**
     * 查询编码生成规则列表
     */
    public List<SysAutoCodeRule> queryList(SysAutoCodeRule bo) ;


    /**
     * 新增编码生成规则
     */
    public Boolean insertByBo(SysAutoCodeRule bo) ;

    /**
     * 修改编码生成规则
     */
    public Boolean updateByBo(SysAutoCodeRule bo);


    /**
     * 批量删除编码生成规则
     */
    public Boolean deleteWithValidByIds(Collection<Long> ids, Boolean isValid) ;

    public SysAutoCodeRule getOne(String ruleCode);

    public List<SysAutoCodeRule> selectAutoCodeList(SysAutoCodeRule sysAutoCodeRule);

    public SysAutoCodeRule findById(Long ruleId);

    public String checkRuleCodeUnique(SysAutoCodeRule sysAutoCodeRule);

    public String checkRuleNameUnique(SysAutoCodeRule sysAutoCodeRule);

    public int insertInfo(SysAutoCodeRule rule);

    public int updateInfo(SysAutoCodeRule rule);

    public int deleteById(Long ruleId);

    public int deleteByIds(Long[] ruleIds);

}
